import request from '@/utils/request'

// 查询款式分类列表
export function listType(data) {
  return request({
    url: '/system/fashion/category/list',
    method: 'post',
    data: data
  })
}

// 查询款式分类列表（排除节点）
export function listTypeExcludeChild(TypeId) {
  return request({
    url: '/system/Type/list/exclude/' + TypeId,
    method: 'get'
  })
}

// 查询款式分类详细
export function getType(TypeId) {
  return request({
    url: '/system/fashion/category/info',
    method: 'post',
    data: {
      id: TypeId
    }
  })
}

// 新增款式分类
export function addType(data) {
  return request({
    url: '/system/fashion/category/add',
    method: 'post',
    data: data
  })
}

// 修改款式分类
export function updateType(data) {
  return request({
    url: '/system/fashion/category/edit',
    method: 'post',
    data: data
  })
}

// 删除款式分类
export function delType(TypeId) {
  return request({
    url: '/system/fashion/category/remove',
    method: 'post',
    data: {
      id: TypeId
    }
  })
}